A reverse proxy is a forwarding topology where the proxy is on behalf of a back-end HTTP server. A reverse proxy is installed within the neighborhood of one or more servers. Typically, reverse proxies are utilized in front of web servers and operate as an application proxy for servers using HTTP. In some cases, a reverse proxy may rewrite content delivered from the web server to the client. For example, a reverse proxy may rewrite a URL of a web page served to a client. Some of the pages served by an HTTP server may include a set-cookie header in the HTTP transaction to set a cookie for the client. In rewriting content, the reverse proxy may rewrite the set-cookie header to have a browser accept and manage the cookie. A reverse proxy may disregard the path and domain values of the set-cookie header in rewriting the cookie. In another case, the reverse proxy may re-write the cookies to encode the path and domain values into an element of the set-cookie header. These re-written set-cookie headers may lead to security leaks and data corruption.